<template>
  <div class="bigbox">
    <div class="header">
      <span><svg-icon iconClass="back" class="zhuo_back"></svg-icon></span>
      <div>支付成功</div>
    </div>
    <div class="wwee">
      <div class="zhifuok">
        <dt>
          <van-icon name="checked" size="100" color="green" />
        </dt>
        <dd>
          <b>支付成功</b>
        </dd>
      </div>
      <div class="zxcv">
        <div class="details">
          <p>
            <span>订单编号</span>
            <span>123123123</span>
          </p>
        </div>
        <div class="details">
          <p>
            <span>订单金额</span>
            <span>{{ this.$route.query.value }}元</span>
          </p>
        </div>
        <div class="details">
          <p>
            <span>支付方式</span>
            <span v-if="this.$route.query.radio == '1'">微信</span>
            <span v-else-if="this.$route.query.radio == '2'">支付宝</span>
            <span v-else>银行卡</span>
          </p>
        </div>
        <div class="details">
          <p>
            <span>支付时间</span>
            <span>{{
              new Date().toLocaleDateString() +
                "-" +
                new Date().toTimeString().slice(0, 8)
            }}</span>
          </p>
        </div>
      </div>
      <div class="dingdan">
        <div class="colorbai">进入订单中心</div>
        <div class="colorlan" @click="gohome()">继续逛逛</div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  methods: {
    gohome() {
      this.$router.push({ path: "/layout/home" });
    },
  },
};
</script>

<style lang="scss" scoped>
.bigbox {
  width: 100%;
  height: 100%;
  background-color: #f2f2f2;
  display: flex;
  flex-direction: column;
  font-size: 18px;
}
.header {
  width: 100%;
  height: 60px;
  background-color: #555882;
  color: #ffffff;
  display: flex;
  line-height: 60px;
  div {
    margin: 0 auto;
    padding-right: 40px;
  }
  span {
    padding-left: 20px;
  }
}
.wwee {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #f3f3f3;
  .zhifuok {
    padding-top: 20px;
    text-align: center;
    height: 200px;
    font-size: 25px;
    background: #fff;

    dd {
      margin-top: 20px;
    }
  }
}
.zxcv {
  margin-top: 20px;
  background: #fff;
  p {
    margin-bottom: 20px;
  }
}
.details {
  width: 100%;
  padding: 0 15px;
  font-size: 18px;
  margin-top: 10px;
  p {
    display: flex;
    justify-content: space-between;
    padding: px2rem(10) 0;
  }
}
.dingdan {
  width: 100%;
  display: flex;
  justify-content: space-around;
  margin-top: 60px;
  div {
    width: 130px;
    height: 35px;
    text-align: center;
    line-height: 35px;
    border-radius: 150px;
    color: #ffffff;
  }
  .colorbai {
    background-color: #484a71;
    border: 1px solid #484a71;
    color: #fff;
  }
  .colorlan {
    background-color: #acacac;
    color: #fff;
  }
}
</style>
